<%@page import="News.entity.International_News"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html>
  <body>
  	<table border="1" align="center" width="500">
		<tr align="center">
			<td>新闻编号</td>		
			<td>新闻内容</td>		
			<td>发布时间</td>		
			<td>浏览人数</td>		
			<td>操作</td>		
		</tr>
		<%
		session.getAttribute("InterList");
		
		
		
		
		
		
		
		
		List<International_News> InList = (List<International_News>)session.getAttribute("InterList");
		for(International_News Inlist:InList){
			int newsid = Inlist.getNewsId();
			String newscont = Inlist.getNewsContent();
			String newstime = Inlist.getTime();
			int newsnor = Inlist.getNumOfRead();
		
		 %>
			<tr align="center">
				<td><%=newsid%></td>
				<td><%=newscont%></td>
				<td><%=newstime%></td>
				<td><%=newsnor%></td>
				<td>
		  		<a href="/NewsPublish/InternationalNewsServlet?opr=del&delid=<%=newsid%>">删除</a> 
		  		<a href="upInternationalNews.jsp">修改</a>
		  		
		  		</td>
			</tr>
		
		<%
		}
		%>
		
		
		<form action="/NewsPublish/InternationalNewsServlet?opr=add" method="post">
			<tr align="center">
				<td><input type="text" id="newsid" name="newsid" value="新闻编号"></td>
				<td><input type="text" id="newscont" name="newscont" value="新闻内容"></td>
				<td><input type="text" id="newstime" name="newstime" value="发布时间"></td>
				<td><input type="text" id="newsnor" name="newsnor" value="访问人数"></td>
				<td><input type="submit" value="新增"></td>
			</tr>		
		</form>
  	</table>
  	
  	<hr>
  		<div style = "text-align:center;">
  		<input type="button" value="返回" onclick="javascript:history.go(-1);">
  		</div>
  </body>
</html>
